<?php 
class Silk_Pms_Block_Adminhtml_Renderer_Action extends Mage_Adminhtml_Block_Widget_Grid_Column_Renderer_Abstract{
	public function render(Varien_Object $row)
	{
	    $tid = $row->getTemplateId();
	    $id = $row->getId();
	    if($tid){
	    	$href = Mage::helper('core/url')->getHomeUrl()."promotion/exchange/view/exchange_id/".$id;
	    	 return '<a href="' . $href . '" target="_blank">' . $this->__('预览') . '</a>';
	    }else{
	    	 return "不可预览";
	    }

	}
}
?>